<?php $__env->startSection('content'); ?>
    <div class="row">
        <div class="col-sm-12">
            <div class="ibox-title">
                <h5>分时在线统计</h5>
            </div>
            <div class="ibox-content">
                <form class="form-horizontal " action="<?php echo e(route('stat.online')); ?>" method="post"
                      enctype="multipart/form-data">
                    <?php echo csrf_field(); ?>

                    <table class="table-striped table-bordered table-hover table-condensed">
                        <tr class="b-group">
                            <td class="b-child" colspan="2">
                                <table class="table-striped table-bordered table-hover table-condensed"
                                       style="margin: 0px;">
                                    <tr class="b-group">
                                        <td>
                                            <?php echo $__env->make('widget.between_datetime',['showEndTime'=>true], array_except(get_defined_vars(), array('__data', '__path')))->render(); ?>
                                        </td>
                                        <td>
                                            <?php echo $__env->make('widget.query_and_refresh', array_except(get_defined_vars(), array('__data', '__path')))->render(); ?>
                                        </td>
                                        <td>
                                            <?php echo $__env->make('widget.dataType', array_except(get_defined_vars(), array('__data', '__path')))->render(); ?>
                                        </td>
                                    </tr>
                                </table>
                            </td>
                        </tr>
                        <tr class="b-group">
                            <th width="10%">
                                <label>全选/不选&nbsp;&nbsp;
                                    <input type="checkbox" checked="checked" value=""
                                           onclick="checkAll(this)"></label>
                            </th>
                            <td class="b-child">
                                <div style="max-height:6.5rem;overflow-y:scroll;">
                                    <?php echo $__env->make('widget.channel', array_except(get_defined_vars(), array('__data', '__path')))->render(); ?>
                                </div>
                            </td>
                        </tr>
                        <tr class="b-group">
                            <th width="10%">
                                <label>全选/不选&nbsp;&nbsp;
                                    <input type="checkbox" checked="checked" value="" onclick="checkAll(this)"></label>
                            </th>
                            <td class="b-child">
                                <div style="max-height:10rem;overflow-y:scroll;">
                                    <?php echo $__env->make('widget.server', array_except(get_defined_vars(), array('__data', '__path')))->render(); ?>
                                </div>
                            </td>
                        </tr>
                    </table>
                </form>
                <div class="clearfix"></div>
            </div>
        </div>
    </div>
    <div class="row">
        <div class="col-sm-12">
            <div class="ibox float-e-margins">
                
                
                
                <div class="ibox-content">
                    <div class="echarts" id="echarts-pie-chart-pay-users" style="height: 400px;"></div>

                    <table class="table table-striped table-bordered table-hover m-t-md text-center tblData"
                           data-toggle="table"
                           data-pagination="true">
                        <thead>
                        <tr>
                            <th class="text-center">时间</th>
                            <th class="text-center">在线人数</th>
                        </tr>
                        </thead>
                        <tbody>
                        <?php $__currentLoopData = $data; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $key => $item): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                            <tr>
                                <td><?php echo e($item['_id']); ?></td>
                                <td><?php echo e($item['total_amounts']); ?></td>
                            </tr>
                        <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                        </tbody>
                    </table>
                </div>
            </div>
        </div>
    </div>
    <script>
    </script>
    <link href="<?php echo e(loadEdition('/admin/css/plugins/datapicker/bootstrap-datepicker.css')); ?>" rel="stylesheet">
    <link href="<?php echo e(loadEdition('/admin/js/plugins/bootstrap-table/bootstrap-table.min.css')); ?>" rel="stylesheet">
<?php $__env->stopSection(); ?>
<?php $__env->startSection('js'); ?>
    <script src="<?php echo e(loadEdition('/admin/js/plugins/datapicker/bootstrap-datepicker.js')); ?>"></script>
    <script src="<?php echo e(loadEdition('/admin/js/plugins/datapicker/bootstrap-datepicker.zh-CN.js')); ?>"></script>

    <script src="<?php echo e(loadEdition('/admin/js/plugins/echarts/echarts.min.js')); ?>"></script>

    <script src="<?php echo e(loadEdition('/admin/js/plugins/bootstrap-table/bootstrap-table.min.js')); ?>"></script>
    <script src="<?php echo e(loadEdition('/admin/js/plugins/bootstrap-table/locale/bootstrap-table-zh-CN.js')); ?>"></script>

    <script src="<?php echo e(loadEdition('/js/global.js')); ?>"></script>
    <script>
        //饼图
        echarts.init(document.getElementById('echarts-pie-chart-pay-users')).setOption({
            title: {
                text: ''
            },
            tooltip: {
                trigger: 'axis'
            },
            legend: {
                data: <?php echo $legendData; ?>

            },
            grid: {
                left: '3%',
                right: '4%',
                bottom: '3%',
                containLabel: true
            },
            toolbox: {
                feature: {
                    saveAsImage: {}
                }
            },
            xAxis: {
                type: 'category',
                boundaryGap: false,
                data: <?php echo $time; ?>,
                axisLabel: {
                    formatter: function (value) {
                        return value.substring(11, 16);
                    }
                }
            },
            yAxis: {
                type: 'value'
            },
            dataZoom: [// 这个dataZoom组件，若未设置xAxisIndex或yAxisIndex，则默认控制x轴。
                {
                    type: 'slider',//这个 dataZoom 组件是 slider 型 dataZoom 组件（只能拖动 dataZoom 组件导致窗口变化）
                    xAxisIndex: 0, //控制x轴
                    start: 0, 	// 左边在 10% 的位置
                    end: 100, 	// 右边在 60% 的位置
                    textStyle: false,
                },
                {
                    type: 'inside',//这个 dataZoom 组件是 inside 型 dataZoom 组件（能在坐标系内进行拖动，以及用滚轮（或移动触屏上的两指滑动）进行缩放）
                    xAxisIndex: 0,//控制x轴
                    start: 10,
                    end: 60
                },
            ],
            series: <?php echo $series; ?>

        });
    </script>
<?php $__env->stopSection(); ?>
<?php echo $__env->make('admin.layouts.layout', array_except(get_defined_vars(), array('__data', '__path')))->render(); ?>